package com.deviceplug;

import android.hardware.usb.UsbDevice;
import android.hardware.usb.UsbDeviceConnection;


public class CameraControlTransfer {
    public CUSBListener usbListener;
    public UsbDevice dev;
    public boolean bPermission;
    public int vid;
    public int pid;
    public int fd;
    public int busnum;
    public int devaddr;
    public String usbFSName;
    public UsbDeviceConnection connection;

    private int controlTransfer(int requestType, int request, int value, int index, byte[] buffer, int length, int timeout)
    {
        try {
            if(connection != null){
                int ret = connection.controlTransfer(requestType, request, value, index, buffer, length, timeout);
                return ret;
            }
        }catch (Exception e){
            e.printStackTrace();
        }
        return -1;
    }

}

